package com.lj.back.manage.scaffold.module.job.DTO;

import com.lj.back.manage.scaffold.common.DTO.PageQuery;
import com.lj.back.manage.scaffold.common.annotation.valid.EnumCheck;
import com.lj.back.manage.scaffold.common.enums.StatusEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;

/**
 * 定时任务日志分页对象
 * @author lv
 * @version 1.0.0
 */
@Data
@ApiModel("定时任务日志分页查询对象")
@EqualsAndHashCode(callSuper=true)
public class ScheduleJobLogPageQuery extends PageQuery {

    /**
     * 执行结果状态 {@link com.lj.back.manage.scaffold.common.enums.StatusEnum}
     */
    @ApiModelProperty(value = "执行结果状态",example = "1")
    @EnumCheck(enumClass = StatusEnum.class,message = "{enum.code.invalid}")
    private String status;

    @ApiModelProperty(value = "定时任务ID",example = "11111")
    private Long jobId;

    @ApiModelProperty(value = "执行时长范围---最小值，与maxTimes配套使用",example = "10")
    private Long minTimes;

    @ApiModelProperty(value = "执行时长范围---最大值，与minTimes配套使用",example = "100")
    private Long maxTimes;

    @ApiModelProperty(value = "根据日志时间查询---起始时间，与endTime配套使用",example = "2020-06-11 14:16:40")
    private LocalDateTime startTime;

    @ApiModelProperty(value = "根据日志时间查询---结束时间，与startTime配套使用",example = "2020-06-11 14:19:30")
    private LocalDateTime endTime;
}
